package library.item;

public class Journal extends Item implements LibraryItem{
	
	public Journal(String identifier, String author, String name, double impactFactor) {
		super(identifier, author, name);
		this.impact = impactFactor;
	}

	double impact;

	@Override
	public String getInfo() {
		StringBuilder info = new StringBuilder();
		info.append("Impact Factor: ").append(impact).append(". ISSN ").append(getIdentifier());
		info.trimToSize();
		return info.toString();
	}

	
	public String toString(){
		StringBuilder string =new StringBuilder();
		string.append(this.getData()).append(". ").append(this.getInfo());
		string.trimToSize();
		return string.toString();
	}

}
